@extends('layout/index')

@section('main')

<div class="mws-panel grid_8">

    <div class="mws-panel-header">
        <span>添加商品图片</span>
    </div>
    <div class="mws-panel-body no-padding">
        <form action="/Admin/goods/goodspic" method="post"   enctype="multipart/form-data" class="mws-form">
            <div class="mws-form-inline">
                
                
                 <div class="mws-form-row bordered">
                    <label class="mws-form-label">商品名称</label>
                    <div class="mws-form-item">
                        <select class="small" name="gid">
                            @foreach($res as $k => $v)
                                <option value="{{ $v->id }}">序号:{{$v->id}}--{{ $v->goodsname }}</option>
                           @endforeach
                        </select>
                    </div>
                 </div>

                 <div class="mws-form-row bordered">
                    <label class="mws-form-label">添加图片</label>
                    <div class="mws-form-item">

                        <img id="img1" src="/upload/1.jpg" alt="" width="100" height="100" onclick='$("#file1").click()'>
                        <img id="img2" src="/upload/1.jpg" alt="" width="100" height="100" onclick='$("#file2").click()'>
                   
                          <div  style="display:none" >
                              <input type="file" name="picname1" id="file1">
                              <input type="file" name="picname2" id="file2">
                         </div>
                    </div>
                 </div>

            </div>
            <div class="mws-button-row">
                {{ csrf_field() }}
                <input type="submit" class="btn btn-danger" value="添加">
                <input type="reset" class="btn " value="重置">
            </div>
        </form> 
    </div>      
</div>


@endsection